﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<title>创建群组 - {site.Name}</title>
<script type="text/javascript" src="{site.Dir}_data/SysConfig.js"></script>
<script type="text/javascript" src="{site.Dir}_libs/jquery-min.js"></script>
<script type="text/javascript" src="{site.Dir}_libs/jquery.form.js"></script>
<script type="text/javascript" src="{site.Dir}scripts/jumbotcms.js?v4"></script>
<link type="text/css" rel="stylesheet" href="{site.Dir}style/global.css" />
<link type="text/css" rel="stylesheet" href="{site.Dir}_libs/jquery.formvalidator/style.css" />
<script src="{site.Dir}_libs/jquery.formvalidator.js" type="text/javascript"></script>

<style type="text/css">
@import url({site.Dir}user/otherfiles/css/style.css);
</style>
<script type="text/javascript">
(function(){
	$(document).ready(function(){
		$("#cancreate{$_cancreate$}").show();
		$('#mtagcreateForm').ajaxForm({
			beforeSubmit: JumbotCms.AjaxFormSubmit,
			success :function(data){
				JumbotCms.Eval(data);
			}
		}); 
		$.formValidator.initConfig({onError:function(msg){}});
		$("#txtTitle")
			.formValidator({tipid:"tipTitle",onshow:"",onfocus:"请输入群组名称",oncorrect:""})
			.InputValidator({min:4,max:30,onerror:"4-30位字符"})
			.AjaxValidator({
			type : "get",
			url:		"ajax.aspx?oper=checkname&time="+(new Date().getTime()),
			datatype : "json",
			success : function(d){	
				if(d.result == "1")
				{
					return true;
				}
				else
				{
					return false;
				}
			},
			buttons: $("#btnSave"),
			error: function(){alert("服务器没有返回数据，可能服务器忙，请重试");},
			onerror : "此名称已经存在",
			onwait : "正在校验群组名称的合法性，请稍候..."
		}).DefaultPassed();
	});
	//Form验证
	JumbotCms.AjaxFormSubmit=function(item){
		try{
			if(jQuery.formValidator.PageIsValid('1'))
			{
				JumbotCms.Loading.show("正在处理，请稍等...");
				return true;
			}else{
				return false;
			}
		}catch(e){
			return false;
		}
	};
})();
</script>
<script type="text/javascript" src="{site.Dir}user/otherfiles/scripts/ajax.js"></script>
</head>
<body>
<iframe frameborder="0" scrolling="no" src="{site.Dir}user/index/index.aspx?do=header" width="100%" height="76" marginwidth="0" marginheight="0" hspace="0" vspace="0" id="ifheader"></iframe>
<!--顶部结束,中框架开始-->
<div id="wrap">
	<div id="main">
		<div id="app_sidebar">
			<ul class="app_list" id="default_userapp">
				<li class="currently"><img src="{site.Dir}user/otherfiles/image/writer_v2/user_home.gif"><a href="{site.Dir}user/index/index.aspx">用户管理中心</a></li>
			</ul>
			<ul class="app_list" id="my_userapp">
				<li class="hr"></li>
				<li><img src="{site.Dir}user/otherfiles/image/writer_v2/contribute.gif"><a href="{site.Dir}user/contribute/index.aspx" target="_blank">我的投稿</a><em></em></li>
				<li><img src="{site.Dir}user/otherfiles/image/app/message.gif"><a href="{site.Dir}user/pmlist/index.aspx">短信</a><em><a href="{site.Dir}user/pmsend/index.aspx">发送</a></em></li>
				<li><img src="{site.Dir}user/otherfiles/image/app/friend.gif"><a href="{site.Dir}user/friendlist/index.aspx">好友</a><em><a href="{site.Dir}user/friendadd/index.aspx">添加</a></em></li>
				<li><img src="{site.Dir}user/otherfiles/image/app/mtag.gif"><a href="{site.Dir}mtag/index/index.aspx">群组</a><em><a href="{site.Dir}user/mtag_thread">话题</a></em></li>
				<li><img src="{site.Dir}user/otherfiles/image/app/favorite.gif"><a href="{site.Dir}user/favorite/index.aspx">收藏夹</a>
			</ul>
		</div>
		<div id="mainarea">
			<h2 class="title"><img src="{site.Dir}user/otherfiles/image/icon/mtag.gif">群组</h2>
			<div class="tabs_header">
				<ul class="tabs">
					<li class="active"><a><span>创建新群组</span></a></li>
					<li><a href="{site.Dir}mtag/view_threadadd/index.aspx"><span>发表新话题</span></a></li>
					<li><a href="{site.Dir}mtag/index/index.aspx"><span>返回我的群组</span></a></li>
				</ul>
			</div>
			<div id="cancreate1" class="c_form" style="display:none;">
				<form id="mtagcreateForm" name="form1" method="post" action="?act=save">
					<table cellspacing="6" cellpadding="6" class="formtable">
						<caption>
						<h2>创建新群组</h2>
						<p>您可以自由创建一个群组，来与组内的成员进行交流讨论。</p>
						</caption>
						<tr>
							<td><div class="l_status">1. <strong>请选择一个群组分类</strong></div>
								<table>
									<tr>
										<td><input type="radio" id="fieldid_1" name="rblSortId" value="1" checked="checked">
											<label for="fieldid_1">自由联盟</label></td>
										<td><input type="radio" id="fieldid_2" name="rblSortId" value="2">
											<label for="fieldid_2">兴趣联盟</label></td>
										<td><input type="radio" id="fieldid_3" name="rblSortId" value="3">
											<label for="fieldid_3">技术交流</label></td>
										<td><input type="radio" id="fieldid_4" name="rblSortId" value="4">
											<label for="fieldid_4">协同合作</label></td>
									</tr>
									<tr></tr>
								</table></td>
						</tr>
						<tr>
							<td><div class="l_status">2. <strong>设置要创建的群组名称</strong></div>
								<input type="text" id="txtTitle" name="txtTitle" value="">
								<div class="ValidatorTip" id="tipTitle" style="width:200px"></div></td>
						</tr>
						<tr>
							<td><input type="submit" id="mtagsubmit" name="mtagsubmit" value="提交" class="submit"></td>
						</tr>
					</table>
				</form>
			</div>
			<div id="cancreate0" style="display:none;">
				<dl class="message">
					<dt><span class="tl"></span><span class="tr"></span>友情提醒</dt>
					<dd><span class="em">您当前不能创建群组，可能原因：</span><br>
						1、您创建的群组已经达到了3个！<br>
						2、管理员关闭了此功能！<br>
						<br>
					</dd>
					<dd class="message_b"><span class="bl"></span><span class="br"></span></dd>
				</dl>
			</div>
		</div>
		<div id="bottom"></div>
	</div>
	<div id="footer" title=""> </div>
</div>
<iframe frameborder="0" scrolling="no" src="{site.Dir}user/index/index.aspx?do=footer" width="100%" height="50" marginwidth="0" marginheight="0" hspace="0" vspace="0" id="iffooter"></iframe>
</body>
</html>
